const Mock = require('mockjs')

const data = Mock.mock({
  'items|5': [{
    // id: '@increment',
    num: '@integer(20201314001, 20201314099)',
    'Account|1': ['test'

    ],
    'state|1': ['已关闭',
      '待发货',
      '已发货'
    ],
    'imgUrl|1': ['https://img.alicdn.com/imgextra/https://img.alicdn.com/imgextra/i4/2206860562597/O1CN01wZzp6B1V3THD3caJg_!!2206860562597.jpg_430x430q90.jpg'

    ],
    graduate_time: '@datetime',
    price: '￥@integer(100, 150)',
    'pay|1': ['未支付', '微信', '支付宝'],
    source: 'App订单',

    numberOrder: 'R@integer(20011024,20011050)'

  }]
})

module.exports = [{
  url: '/vue-admin-template/orders/list',
  type: 'get',
  response: () => {
    const items = data.items
    return {
      code: 20000,
      data: {
        total: items.length,
        items: items
      }
    }
  }
}]
